package com.hong.concurrent.chapter11;

/**
 * @Author csh
 * @Description
 * @Date 2018/7/7 11:13
 */
public class QueryFromHttpAction {

    public void execute(){
        Context context = ActionContext.getActionContext().getContext();
        String name =context.getName();
        String cardId = getCardId(name);
        context.setCardId(cardId);
    }

    private String getCardId(String name){
        try {
            Thread.sleep(1000L);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        return "461343131"+Thread.currentThread().getId();
    }
}
